cmake_minimum_required(VERSION 3.25)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_INCLUDE_CURRENT_DIR ON)

set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/x64/lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/x64/bin)

project(MarkMakerPlugin)

add_subdirectory(WithMatlab)
add_subdirectory(DynamicMatlab)


# 构建测试代码
find_package(OpenCV REQUIRED)

if (NOT (${OpenCV_VERSION} STREQUAL "3.4.13"))
    MESSAGE(STATUS "当前OpenCV version: " ${OpenCV_VERSION})
    message("最好是3.4.13，-DOpenCV_DIR=\".../build/x64/vc15/lib\"指定")
endif ()

add_executable(plugin_test plugin_test.cpp)
target_link_libraries(plugin_test PRIVATE ${OpenCV_LIBS})
target_include_directories(plugin_test PRIVATE ${OpenCV_INCLUDE_DIRS})
